package com.jzt.jk.open.api.manage.infrastructure.repository.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.jzt.jk.open.api.manage.infrastructure.repository.po.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

/**
 * 作者：lizw <br/>
 * 创建时间：2021/01/21 10:28 <br/>
 */
@Repository
@Mapper
public interface UserMapper extends BaseMapper<User> {
    @Select("select * from user where (login_name=#{loginNameOrTelephone} or telephone=#{loginNameOrTelephone}) limit 1")
    User getByLoginNameOrTelephone(@Param("loginNameOrTelephone") String loginNameOrTelephone);

}
